home *** CD-ROM | disk | FTP | other *** search
/ Sprite 1984 - 1993 / Sprite 1984 - 1993.iso / src / boot / netBoot.new / h / eeprom.h < prev    next >
Encoding:
C/C++ Source or Header  |  1990-12-19  |  7.0 KB  |  190 lines

  1.  
  2. /*      @(#)eeprom.h 1.1 86/09/27 SMI      */
  3.  
  4. /*
  5.  * Copyright (c) 1986 by Sun Microsystems, Inc.
  6.  */
  7.  
  8. /*
  9.  * This structure defines the contents to the EEPROM for the Sun-3.
  10.  * It is divided into a diagnostic section, a reserved section,
  11.  * a ROM section, and a software section (defined in detail
  12.  * elsewhere).
  13.  */
  14. #ifndef _EPROM_
  15. #define _EPROM_
  16.  
  17. struct    eeprom {
  18.     struct    ee_diag {        /* diagnostic's area of EEPROM */
  19. /* 0x000 */    u_int    eed_test;    /* diagnostic test write area */
  20. /* 0x004 */    u_short    eed_wrcnt[3];    /* diag area write count (3 copies) */
  21.         short    eed_nu1;    /* not used */
  22. /* 0x00c */    u_char    eed_chksum[3];    /* diag area checksum (3 copies) */
  23.         char    eed_nu2;    /* not used */
  24. /* 0x010 */    time_t    eed_hwupdate;    /* date of last hardware update */
  25. /* 0x014 */    char    eed_memsize;    /* MB's of memory in system */
  26. /* 0x015 */    char    eed_memtest;    /* MB's of memory to test on powerup */
  27. /* 0x016 */    char    eed_scrsize;    /* screen size, in pixels */
  28. #define    EED_SCR_1152X900    0x00
  29. #define    EED_SCR_1024X1024    0x12
  30. #define EED_SCR_1600X1280       0x13    /* new for hi rez */
  31. #define EED_SCR_1440X1440       0x14
  32. /* 0x017 */    char    eed_dogaction;    /* action to take on watchdog reset */
  33. #define    EED_DOG_MONITOR        0x00    /* return to monitor command level */
  34. #define    EED_DOG_REBOOT        0x12    /* perform power on reset and reboot */
  35. /* 0x018 */    char    eed_defboot;    /* default boot? */
  36. #define    EED_DEFBOOT        0x00    /* do default boot */
  37. #define    EED_NODEFBOOT        0x12    /* don't do default boot */
  38. /* 0x019 */    char    eed_bootdev[2];    /* name of boot device (e.g. xy, ie) */
  39. /* 0x01b */    char    eed_bootctrl;    /* controller number to boot from */
  40. /* 0x01c */    char    eed_bootunit;    /* unit number to boot from */
  41. /* 0x01d */    char    eed_bootpart;    /* partition number to boot from */
  42. /* 0x01e */    char    eed_kbdtype;    /* non-Sun keyboard type - for OEM's */
  43. #define    EED_KBD_SUN    0        /* one of the Sun keyboards */
  44. /* 0x01f */    char    eed_console;    /* device to use for console */
  45. #define    EED_CONS_BW    0x00        /* use b&w monitor for console */
  46. #define    EED_CONS_TTYA    0x10        /* use tty A port for console */
  47. #define    EED_CONS_TTYB    0x11        /* use tty B port for console */
  48. #define    EED_CONS_COLOR    0x12        /* use color monitor for console */
  49. /* 0x020 */    char    eed_showlogo;    /* display Sun logo? */
  50. #define    EED_LOGO    0x00
  51. #define    EED_NOLOGO    0x12
  52. /* 0x021 */    char    eed_keyclick;    /* keyboard click? */
  53. #define    EED_NOKEYCLICK    0x00
  54. #define    EED_KEYCLICK    0x12
  55. /* 0x022 */    char    eed_diagdev[2]; /* name of boot device (e.g. xy, ie) */
  56. /* 0x024 */    char    eed_diagctrl;   /* controller number to boot from */
  57. /* 0x025 */    char    eed_diagunit;   /* unit number to boot from */
  58. /* 0x026 */    char    eed_diagpart;   /* partition number to boot from */
  59. /* 0x027 */    char    eed_diagnu;     /* not used */
  60. /* 0x028 */    char    eed_diagpath[40]; /* boot path of diagnostic */
  61. /* 0x050 */     char    eed_colsize;   /* number of columns */
  62. /* 0x051 */     char    eed_rowsize;   /* number of rows */
  63. /* 0x052 */    char    eed_nu5[6];    /* not used */
  64. /* 0x058 */    struct    eed_tty_def {    /* tty port defaults */
  65.             char    eet_sel_baud;    /* user specifies baud rate */
  66. #define    EET_DEFBAUD    0x00
  67. #define    EET_SELBAUD    0x12
  68.             u_char    eet_hi_baud;    /* upper byte of baud rate */
  69.             u_char    eet_lo_baud;    /* lower byte of baud rate */
  70.             u_char    eet_rtsdtr;    /* flag for dtr and rts */
  71. #define NO_RTSDTR    0x12
  72.             char    eet_unused[4];
  73.         } eed_ttya_def, eed_ttyb_def;
  74. /* 0x068 */    char    eed_banner[80];    /* banner if not displaying Sun logo */
  75.                     /* last two chars must be \r\n (XXX - why not \0?) */
  76. /* 0x0b8 */    u_short    eed_pattern;    /* test pattern - must contain 0xAA55 */
  77. /* 0x0ba */       short   eed_nu6;        /* not used */
  78. /* 0x0bc */    struct    eed_conf {    /* system configuration, by slot */
  79.             union {
  80.             struct    eec_gen {
  81.                 char    eec_type;    /* type of this board */
  82.                 char    eec_size[7];    /* size of each entry */
  83.             } eec_gen;
  84.  
  85. #define    EEC_TYPE_CPU    0x01            /* cpu */
  86.             struct    eec_cpu {
  87.                 char    eec_type;    /* type of this board */
  88.                 char    eec_cpu_memsize;    /* MB's on cpu */
  89.                 int    eec_cpu_unused:6;
  90.                 int    eec_cpu_dcp:1;        /* dcp? */
  91.                 int    eec_cpu_68881:1;    /* 68881? */
  92.                 char    eec_cpu_cachesize;    /* KB's in cache */
  93.             } eec_cpu;
  94.  
  95. #define    EEC_TYPE_MEM    0x02            /* memory board */
  96.             struct    eec_mem {
  97.                 char    eec_type;    /* type of this board */
  98.                 char    eec_mem_size;    /* MB's on card */
  99.             } eec_mem;
  100.  
  101. #define    EEC_TYPE_COLOR    0x03            /* color frame buffer */
  102.             struct    eec_color {
  103.                 char    eec_type;    /* type of this board */
  104.                 char    eec_color_type;
  105. #define    EEC_COLOR_TYPE_CG2    2    /* cg2 color board */
  106. #define    EEC_COLOR_TYPE_CG3    3    /* cg3 color board */
  107.             } eec_color;
  108.  
  109. #define    EEC_TYPE_BW    0x04            /* b&w frame buffer */
  110.  
  111. #define    EEC_TYPE_FPA    0x05            /* floating point accelerator */
  112.  
  113. #define    EEC_TYPE_DISK    0x06            /* SMD disk controller */
  114.             struct    eec_disk {
  115.                 char    eec_type;    /* type of this board */
  116.                 char    eec_disk_type;    /* controller type */
  117.                 char    eec_disk_ctlr;    /* controller number */
  118.                 char    eec_disk_disks;    /* number of disks */
  119.             } eec_disk;
  120.  
  121. #define    EEC_TYPE_TAPE    0x07            /* 1/2" tape controller */
  122.             struct eec_tape {
  123.                 char    eec_type;    /* type of this board */
  124.                 char    eec_tape_type;    /* controller type */
  125. #define    EEC_TAPE_TYPE_XT    1    /* Xylogics 472 */
  126. #define    EEC_TAPE_TYPE_MT    2    /* TapeMaster */
  127.                 char    eec_tape_ctlr;    /* controller number */
  128.                 char    eec_tape_drives;/* number of drives */
  129.             } eec_tape;
  130.  
  131. #define    EEC_TYPE_ETHER    0x08            /* Ethernet controller */
  132.  
  133. #define    EEC_TYPE_TTY    0x09            /* terminal multiplexer */
  134.             struct eec_tty {
  135.                 char    eec_type;    /* type of this board */
  136.                 char    eec_tty_lines;    /* number of lines */
  137.             } eec_tty;
  138.  
  139. #define    EEC_TYPE_GPGB    0x0a            /* graphics processor/buffer */
  140.  
  141. #define    EEC_TYPE_DCP    0x0b            /* DCP ??? XXX */
  142.  
  143. #define    EEC_TYPE_SCSI    0x0c            /* SCSI controller */
  144.             struct    eec_scsi {
  145.                 char    eec_type;    /* type of this board */
  146.                 char    eec_scsi_type;    /* controller type */
  147.                 char    eec_scsi_tapes;    /* number of tapes */
  148.                 char    eec_scsi_disks;    /* number of disks */
  149.             } eec_scsi;
  150.  
  151. #define    EEC_TYPE_END    0xff            /* end of card cage */
  152.             } eec_un;
  153.         } eed_conf[13];
  154. /* 0x124 */    char    eed_resv[0x500-0x124];    /* reserved */
  155.     } ee_diag;
  156.  
  157.     struct    ee_resv {        /* reserved area of EEPROM */
  158. /* 0x500 */    u_short    eev_wrcnt[3];    /* write count (3 copies) */
  159.         short    eev_nu1;    /* not used */
  160. /* 0x508 */    u_char    eev_chksum[3];    /* reserved area checksum (3 copies) */
  161.         char    eev_nu2;    /* not used */
  162. /* 0x50c */    char    eev_resv[0x600-0x50c];
  163.     } ee_resv;
  164.  
  165.     struct    ee_rom {        /* ROM area of EEPROM */
  166. /* 0x600 */    u_short    eer_wrcnt[3];    /* write count (3 copies) */
  167.         short    eer_nu1;    /* not used */
  168. /* 0x608 */    u_char    eer_chksum[3];    /* ROM area checksum (3 copies) */
  169.         char    eer_nu2;    /* not used */
  170. /* 0x60c */    char    eer_resv[0x700-0x60c];
  171.     } ee_rom;
  172.  
  173.     /*
  174.      * The following area is reserved for software (i.e. UNIX).
  175.      * The actual contents of this area are defined elsewhere.
  176.      */
  177. #ifndef EE_SOFT_DEFINED
  178.     struct    ee_softresv {        /* software area of EEPROM */
  179. /* 0x700 */    u_short    ees_wrcnt[3];    /* write count (3 copies) */
  180.         short    ees_nu1;    /* not used */
  181. /* 0x708 */    u_char    ees_chksum[3];    /* software area checksum (3 copies) */
  182.         char    ees_nu2;    /* not used */
  183. /* 0x70c */    char    ees_resv[0x800-0x70c];
  184.     } ee_soft;
  185. #else
  186.     struct    ee_soft ee_soft;
  187. #endif
  188. };
  189. #endif !_EPROM_
  190.